package com.ruoyi.dynamic.service;


import com.baomidou.mybatisplus.extension.service.IService;
import com.ruoyi.common.core.pojo.result.Pages;
import com.ruoyi.dynamic.model.pojo.entity.RoomQuizRecord;
import com.ruoyi.dynamic.model.pojo.request.app.AppRoomAuctionStartRequest;
import com.ruoyi.dynamic.model.pojo.request.app.AppRoomQuizAddRequest;
import com.ruoyi.dynamic.model.pojo.request.app.AppRoomQuizSearchRequest;
import com.ruoyi.dynamic.model.pojo.request.app.AppRoomWishCloseRequest;

/**
 * <p>
 * 语聊房问答 服务类
 * </p>
 *
 * @author Gnc
 * @since 2024-12-26
 */
public interface IRoomQuizRecordService extends IService<RoomQuizRecord> {

    /**
     * 用户提问问答游戏
     */
    void quizAdd(Long userId, AppRoomQuizAddRequest request);


    /**
     * 问答列表
     */
    Pages<RoomQuizRecord> listPage(AppRoomQuizSearchRequest request, Long userId);

    /**
     * 切换下一个问题
     */
    boolean changeStatus(AppRoomAuctionStartRequest request, Long userId);

    /**
     * 主播结束问答游戏
     */
    boolean overGame(Long id, Long userId);

    /**
     * 主播删除问答
     */
    boolean delRecord(AppRoomAuctionStartRequest request, Long userId);

    /**
     * 置顶问答
     *
     * @param request
     * @param userId
     * @return
     */
    boolean topRecord(AppRoomAuctionStartRequest request, Long userId);

    /**
     * 开启或者关闭 提问状态
     */
    void openOrStop(Integer status, Long rooomId, String quizContent, Long quizGiftId, String quizGiftImg);

    /**
     * 判断用户是否提问过
     */
    boolean isUserQuiz(Long roomId, Long userId);

    /**
     * 关闭当前提问
     */
    boolean closeQuiz(AppRoomWishCloseRequest request, Long userId);

}
